package cn.cqie.attendance.common.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author FallInLove
 * @since 2021-06-22
 */
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@ApiModel(value="Teacher对象", description="")
public class Teacher extends User implements Serializable {

    private static final long serialVersionUID = 1L;

    public Teacher() {

    }

    @ApiModelProperty(value = "教师Id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    private String tokenId;

    public String getTokenId() {
        return tokenId;
    }

    public void setTokenId(String tokenId) {
        this.tokenId = tokenId;
    }

    @ApiModelProperty(value = "老师名")
    @TableField("teacher_name")
    private String teacherName;

    @ApiModelProperty(value = "工号")
    @TableField("job_number")
    private String jobNumber;

    @ApiModelProperty(value = "密码")
    @TableField("password")
    private String password;

    @ApiModelProperty(value = "身份证")
    @TableField("identity")
    private String identity;

    @ApiModelProperty(value = "手机号")
    @TableField("phone")
    private String phone;

    @ApiModelProperty(value = "0 女 1 男")
    private Long gender;

    @ApiModelProperty(value = "0 无效 1 有效")
    @TableField("status")
    private Integer status;

    @ApiModelProperty(value = "职位")
    private Integer positionId;

    @ApiModelProperty(value = "0 普通老师 1 管理员")
    @TableField("role")
    private Integer role;

    @ApiModelProperty(value = "登录次数")
    @TableField("login_times")
    private Integer loginTimes;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTeacherName() {
        return teacherName;
    }

    public void setTeacherName(String teacherName) {
        this.teacherName = teacherName;
    }

    public String getJobNumber() {
        return jobNumber;
    }

    public void setJobNumber(String jobNumber) {
        this.jobNumber = jobNumber;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getIdentity() {
        return identity;
    }

    public void setIdentity(String identity) {
        this.identity = identity;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Long getGender() {
        return gender;
    }

    public void setGender(Long gender) {
        this.gender = gender;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getPositionId() {
        return positionId;
    }

    public void setPositionId(Integer positionId) {
        this.positionId = positionId;
    }

    public Integer getRole() {
        return role;
    }

    public void setRole(Integer role) {
        this.role = role;
    }

    @Override
    public Integer getLoginTimes() {
        return loginTimes;
    }

    public void setLoginTimes(Integer loginTimes) {
        this.loginTimes = loginTimes;
    }

    public Teacher(String tokenId, Integer loginTimes) {
        super(tokenId, loginTimes);
    }
}